package com.itheima.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.itheima.dto.MidDto;
import com.itheima.entity.UserLikeMessage;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
* @author 51585
* @description 针对表【user_like_message】的数据库操作Mapper
* @createDate 2022-12-13 08:57:29
* @Entity com.itheima.entity.UserLikeMessage
*/
@Mapper
public interface UserLikeMessageMapper extends BaseMapper<UserLikeMessage> {

    /**
     * 新增或更新user_like_message
     * @param messageId
     * @param userId
     * @param status
     */
    void mqOperation(@Param("messageId") Integer messageId, @Param("userId") String userId, @Param("status")Integer status);

    /**
     * 汇总用户点赞他人次数
     * @param userIdList 用户id集合
     * @return List
     */
    List<MidDto> totalSendLikeCount(@Param("list") List<String> userIdList);
}




